import { useTranslations } from 'next-intl';
import Link from 'next-intl/link';

export default function Home() {
  const t = useTranslations('Index');

  return (
    <div
      style={{
        maxWidth: 1280,
        margin: '0 auto',
        padding: '2rem',
        textAlign: 'center',
      }}
    >
      <h1 className="text-4xl font-bold mb-8">{t('title')}</h1>
      <p className="mb-4">{t('description')}</p>
      <div className="flex justify-center gap-4">
        <Link href="/" locale="en" className="text-blue-500 hover:text-blue-700">
          English
        </Link>
        <Link href="/" locale="zh" className="text-blue-500 hover:text-blue-700">
          中文
        </Link>
      </div>
    </div>
  );
}